<template>
  <div>
    <div class="flex-box">
      <div v-if="perShow1" class="flex-item" @click="$router.push('/companyInvestigation')">
        <div class="content">
          <img src="../assets/img/qiyezoufang.png" />
          <div class="title">企业走访</div>
        </div>
      </div>
      <div v-if="perShow2" class="flex-item" @click="$router.push('/questionFill')">
        <div class="content">
          <img src="../assets/img/wentitianbao.png" />
          <div class="title">问题填报</div>
        </div>
      </div>
      <div v-if="perShow3" class="flex-item" @click="$router.push('/visitRecord')">
        <div class="content">
          <img src="../assets/img/zoufangjilu.png" />
          <div class="title">走访记录</div>
        </div>
      </div>
      <div v-if="perShow4" class="flex-item" @click="$router.push('/questionBank')">
        <div class="content">
          <img src="../assets/img/wentiku.png" />
          <div class="title">问题库</div>
        </div>
      </div>
      <div v-if="perShow5" class="flex-item" @click="$router.push('/policyDocument')">
        <div class="content">
          <img src="../assets/img/zhengcewenjian.png" />
          <div class="title">政策文件</div>
        </div>
      </div>
    </div>
  </div>
</template>

<script>
export default {
  data() {
    return {
      perShow1:false,
      perShow2:false,
      perShow3:false,
      perShow4:false,
      perShow5:false,
    };
  },
  created() {
    this.$hasPermiss(['钉钉企业走访','钉钉问题填报','钉钉走访记录','钉钉问题库','钉钉政策文件'],['perShow1','perShow2','perShow3','perShow4','perShow5'])
  },
  methods: {},
};
</script>

<style scoped lang="less">
.flex-box {
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  margin: 0 50px;
}
.flex-item {
  position: relative;
  width: 40%;
  height: 100px;
  text-align: center;
  background: #fff;
  margin: 30px 0 0;
  border-radius: 10px;
  box-shadow: 2px 2px 2px 2px rgba(0, 0, 0, 0.1);
}
.content {
  position: absolute;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%);
  width: 80px;
  text-align: center;
}
img {
  height: 40px;
  margin-top: 8px;
}
.title {
  color: #1296db;
  font-size: 14px;
  height: 30px;
  line-height: 30px;
  text-align: center;
}
</style>
